home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / sys / amiga / programmer / 553 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  977 b 

  1. Path: news.genie.net!usenet
  2. From: i.einman@genie.com (IAN J. EINMAN)
  3. Newsgroups: comp.sys.amiga.programmer
  4. Subject: Re: LoadRGB32()
  5. Date: 9 Jan 1996 04:28:37 GMT
  6. Organization: via GEnie Services (1-800-638-9636 or info@genie.com)
  7. Sender: i.einman@genie.com (IAN J. EINMAN)
  8. Message-ID: <4csqtl$ob3@rock101.genie.net>
  9. NNTP-Posting-Host: rock103.is.ge.com
  10.  
  11. It needs, the viewport, and a table in a certain format:
  12.  
  13. A series of records, like this...
  14.  
  15. dc.w (number of colors to load)
  16. dc.w (first color)
  17. dc.l r, g, b, ...  (left justifies fraction)
  18.  
  19. repeat this as much as necessary; terminate with a count value of zero.
  20.  
  21. For example:
  22.  
  23. unsigned long junk[] =
  24. {
  25.    2<<16 | 4,
  26.    0xFFFFFFFF, 0x7FFFFFFF, 0x00000000,
  27.    0x00000000, 0x00000000, 0xA0000000,
  28.    0
  29. }
  30.  
  31. LoadRGB32(viewp, junk);
  32.  
  33. will make color 4 be orange and color 5 be blue...  The left justified fraction
  34. is importand, just shift the colors over three bytes if they are 8 bit descriptors
  35. like such found in an IFF ILBM.
  36.  
  37.